
#ifndef __adc_api_h_
#define __adc_api_h_

#define WATERTEMP_SN        0
#define OILLEVEL_SN   		1
#define OILTEM_SN  			1

#define WATERTEMP_CH       1
#define OILLEVEL_CH        2
#define OILTEM_CH  		   3

#define Motor_Range 	44
typedef struct
{
    uint16_t buf[8];
    uint64_t sum;
    unsigned cnt :3;
} S_MeasureAD;
extern S_MeasureAD MeasureAD[3];
extern uint16_t OilTemAD,OilLevelAD,WaterTemAD;

void ADC_init(void);
uint16_t AD_Filter(uint8_t channal);
void Measure_OilLevel(void);
void Measure_OilTem(void);
void Measure_Step(void);
#endif


